package tk.mybatis.springboot.share.util;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import tk.mybatis.springboot.constants.RedisCache;

public class SystemUtils {
	private static Logger logger = LogManager.getLogger(SystemUtils.class);
	// 当前类对象
	private static SystemUtils systemUtils = null;
	public void servletContextInit() {
		PropertiesUtil.baseProperties = PropertiesUtil.getProperties("message.properties");
//		RedisCache.clearAll();
		logger.info("message文件:" + PropertiesUtil.baseProperties);
	}
	
	//单例操作
	public static SystemUtils getSystemUtils() {
		if (systemUtils == null) {
			systemUtils = new SystemUtils();
		}
		return systemUtils;
	}
}
